<!DOCTYPE html>
<html class="html">
	<head>
		<title>New</title>	
		<script type="text/javascript">
			function set()
			{
				//Get the passed parameters
				var Args = location.search.substring(1);
				var id = Args.split('=')[1]; 
				//Show data according to passed parameters
				var title=document.getElementById("title");
				var body=document.getElementById("body");
				if(id==0)
					title.innerHTML="(NEW) Metro line 5";
				if(id==1)
					title.innerHTML="Route of bus 113 changed";
				if(id==2)
					title.innerHTML="Title 2";
				if(id==3) 
					title.innerHTML="15% Raise for all of the workers";
				if(id==4)
					title.innerHTML="My experience with the new red buses";
				if(id==5)
					title.innerHTML="Title 5";
				if(id==6)
					title.innerHTML="Torn out chairs on Bus 151";
				if(id==7)
					title.innerHTML="Metro Line 4 and the daily delays";
				if(id==8)
					title.innerHTML="Title 8";				
			}
			
			function PostComment()
			{
				var comment = document.getElementById("my_comments").comment.value;
				var divTag = document.createElement("comment");
				divTag.id = "comment";
				divTag.innerHTML = "<br />"+comment+"<br />";
				divTag.style.color= "#555555";
				divTag.style.fontStyle="italic";
				var textBody = document.getElementById("textBody");
				textBody.appendChild(divTag);
				document.getElementById("my_comments").comment.value = "";
			}
			
			function toggleEdit()
			{
				alert("Toggle edit");
			}
		</script>
		<!-- JavaScripts --->
		<script src="js/ratingPlugin/jquery.js"></script>
		<script src="js/ratingPlugin/jquery.MetaData.js"></script>
		<script src="js/ratingPlugin/jquery.rating.js"></script>
		<script src="js/ratingPlugin/jquery.rating.pack.js"></script>
		<script src="js/ratingPlugin/documentation.js"></script>
		<!-- CSS -->
		<link rel="stylesheet" href="css/ratingPlugin/jquery.rating.css" />
		<link rel="stylesheet" href="css/ratingPlugin/documentation.css" />
	</head>
	<body onLoad="set()">
		<table border="0" cellpadding="10" width="100%" summary="">
			<tr>
				<td><font size="3"><b><div id="title"></div></b></font></td>
				<td align="right"><input type="button" id="edit" onClick="location.href='newEntry.html?id=4'" value="Edit"/></td>
			</tr>
			<tr>
				<td colspan="2" id="textBody">
				<div id="body">
					Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam at sem sed eros malesuada dictum. Pellentesque dapibus eros at lectus pellentesque placerat. Nulla sed elit nunc, quis tincidunt est. Sed non massa mi, rutrum congue tellus. Praesent sagittis dolor eget magna faucibus quis vestibulum mauris mollis. Mauris semper odio a erat tincidunt aliquet sed in nulla. Pellentesque mollis ante et metus mattis ac cursus nulla iaculis. Maecenas lectus dolor, porta non imperdiet sit amet, mollis in turpis. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Duis in tellus quis est viverra posuere quis sit amet eros. Fusce nunc felis, vulputate a dictum vitae, feugiat nec ante. Duis ac lorem ut diam varius suscipit.
					<br /><br />
					Duis in consectetur nulla. Etiam semper semper lectus, vel tincidunt tellus consectetur non. Donec a orci lorem, ac commodo lorem. Duis aliquet, orci id consectetur porta, risus dolor pretium sem, porta porttitor dolor lectus quis orci. Duis placerat consectetur dignissim. Ut vitae nibh quis nisl semper adipiscing sed non odio. Morbi venenatis tortor ac massa facilisis tempor. Fusce lacus orci, sodales sollicitudin sodales id, ornare et tellus. Phasellus purus enim, auctor suscipit molestie et, pulvinar eget dolor. Aenean quis nunc vel risus sagittis scelerisque in ac est.
					<br /><br />
					Cras sollicitudin enim tempor mauris tempor ornare. Nam id erat ut quam adipiscing vestibulum. Curabitur viverra, magna aliquet hendrerit suscipit, tortor risus imperdiet elit, eu volutpat quam neque non metus. Mauris auctor laoreet elit et eleifend. Fusce nec neque ut eros mattis varius sit amet vitae massa. Nulla euismod, orci nec mollis auctor, ipsum lacus consequat justo, non imperdiet tortor sapien quis ipsum. Sed suscipit, felis a gravida auctor, velit quam sagittis augue, at lobortis mauris felis eu neque. Nullam dapibus laoreet mauris, a placerat velit ultricies in. Aliquam in rhoncus purus. Nam et risus sed diam semper lobortis sit amet id quam. Praesent lobortis scelerisque ipsum ultrices vehicula. Sed rutrum hendrerit mi, non mollis metus pulvinar in. 
				</div>
				</td>
			</tr>
			<tr>
				<td width="85%">
					<br /><br />
					<h1>Leave a comment?</h1>
					<br/><br />
					<b>Your Rating:</b>
					<div>
					<input name="star1" type="radio" class="star"/>
					<input name="star1" type="radio" class="star"/>
					<input name="star1" type="radio" class="star"/>
					<input name="star1" type="radio" class="star"/>
					<input name="star1" type="radio" class="star"/>	
					</div>
					<br/><br/>
					<form id="my_comments">
						<textarea id="comment" rows="2" cols="110"></textarea>
						<br />
						<input type="button" value="Post" onClick="PostComment()"/>
					</form>	
				</td>
				<td valign="top">	
					<input align="right" name="star" type="radio" class="star" disabled="disabled"/>
					<input align="right" name="star" type="radio" class="star" disabled="disabled"/>
					<input align="right" name="star" type="radio" class="star" disabled="disabled" checked="checked"/>
					<input align="right" name="star" type="radio" class="star" disabled="disabled"/>
					<input align="right" name="star" type="radio" class="star" disabled="disabled"/>
				</td>
			</tr>
		</table>
	</body>
</html>